<?php
class MymissionAction extends MissionAction {
	public function index(){
		$mission=A('Intesys/Mission');
		$mission->mymission();
	}
	public function missioncount(){
		$missioncount = array();
		$map = "(member_id = ".$this ->memberInfo['id']." ) ";
		$missioncount['all'] = $this -> dao->where($map) -> count();
		$missioncount['state01'] = $this -> dao->where($map.' and state = -1') -> count();
		$missioncount['state0'] = $this -> dao->where($map.' and state = 0') -> count();
		$missioncount['state1'] = $this -> dao->where($map.' and state = 1') -> count();
		$missioncount['state2'] = $this -> dao->where($map.' and state = 2') -> count();
		$missioncount['state3'] = $this -> dao->where($map.' and state = 3') -> count();
		$this->assign('missioncount', $missioncount);
		
		$this->display();
	}
}